<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">
	<title>宝钢彩涂板管理后台</title>
	<link rel="stylesheet" href="/static/css/normalize.css">
	<link rel="stylesheet" href="/static/css/add.css">
	<link rel="stylesheet" href="/static/css/color-style.css">
	<link rel="stylesheet" href="/static/css/font-awesome.min.css">
	<script type="text/javascript" src="/js/jquery-3.2.1.min.js"></script>
	<script type="text/javascript" src="/js/ueditor.config.js"></script>
	<script type="text/javascript" src="/js/ueditor.all.min.js"></script>
	<script type="text/javascript" src="/js/zh-cn.js"></script>
	<script type="text/javascript" src="/js/common.js"></script>
</head>
<body>
<div class="form-box">
	<div class="top-bar">
		<h5 class="nav-title">编辑案例</h5>
		<div class="button-container">
			<a href="/admin/cases/lst" class='button -green center' style="width: 60px; height: 30px;">返回</a>
		</div>
	</div>
	<form action="/admin/cases/edit" method="POST" enctype="multipart/form-data">
		<input type="hidden" name="id" value="{$case.id}">
		<div class="case-admin-left">
			<input value="{$case.title}" type="text" class="form-control" name="title" id="title" placeholder="在此输入文章标题" value="">
			<br>
			<input value="{$case.date}" type="text" class="form-control" name="date" id="date" placeholder="在此输入时间" value="">
			<br>
			<input value="{$case.environment}" type="text" class="form-control" name="environment" id="environment" placeholder="在此输入环境" value="">
			<br>
			<input value="{$case.industry}" type="text" class="form-control" name="industry" id="industry" placeholder="在此输入行业" value="">
			<br>
			<input value="{$case.variety}" type="text" class="form-control" name="variety" id="variety" placeholder="在此输入品种" value="">
			<script id="md-editor2" type="text/plain" style="height: 300px; margin-top: 10px; width: 100%;"><?php echo $case['content']; ?></script>
		</div>
		<div class="case-admin-right">
			<div class="panel">
    			<div class="panel-heading">
    				<h3 class="panel-title">缩略图</h3>
    			</div>
    			<div class="panel-body">
    				<div class="form-group">
						<div id="photo1">
							<input type="file" id="imagies" onClick="uploadPhoto('#imagies','photo1')" / style="margin-bottom: 5px;">
							<img src="{$case.imagies}" class="img-case-dp" style="width: 120px; height: 85px;">
							<input type="hidden" name="imagies" value="{$case.imagies}">
							<p style="color: red; font-size: 12px; margin-top: 5px;">需等待大约5秒钟！</p>
						</div>
    				</div>
    			</div>
    		</div>
            <div class="panel">
                <div class="panel-heading">
                    <h3 class="panel-title">案例图片</h3>
                </div>
                <div class="panel-body">
                    <div class="form-group">
						<div id="photo2" class="photo">
							<input type="file" id="mul_image0" onClick="uploadPhoto('#mul_image1','photo2')" / style="margin-bottom: 5px;">
							<img src="{$case.mul_image.0}" class="img-case-dp" style="width: 120px; height: 85px;">
							<input type="hidden" name="mul_image0" value="{$case.mul_image[0]}">
						</div>
						<div id="photo3" class="photo">
							<input type="file" id="mul_image1" onClick="uploadPhoto('#mul_image1','photo3')" / style="margin-bottom: 5px;">
							<img src="{$case.mul_image.1}" class="img-case-dp" style="width: 120px; height: 85px;">
							<input type="hidden" name="mul_image1" value="{$case.mul_image[1]}">
						</div>
						<div id="photo4" class="photo">
							<input type="file" id="mul_image2" onClick="uploadPhoto('#mul_image2','photo4')" / style="margin-bottom: 5px;">
							<img src="{$case.mul_image.2}" class="img-case-dp" style="width: 120px; height: 85px;">
							<input type="hidden" name="mul_image2" value="{$case.mul_image[2]}">
						</div>
						<div id="photo5" class="photo">
							<input type="file" id="mul_image3" onClick="uploadPhoto('#mul_image3','photo5')" / style="margin-bottom: 5px;">
							<img src="{$case.mul_image.3}" class="img-case-dp" style="width: 120px; height: 85px;">
							<input type="hidden" name="mul_image3" value="{$case.mul_image[3]}">
						</div>
						<p style="color: red; font-size: 12px; margin-top: 5px;">需等待大约5秒钟！</p>
                    </div>
                </div>
            </div>
			<div class="panel">
				<div class="panel-heading">
					<h3 class="panel-title">发布选项</h3>
				</div>
				<div class="panel-body">
					<div class="form-group">
						<div class="button-container">
							<button type="submit" class="button -blue center" style="width: 100px;">确认</button>
						</div>
					</div>
				</div>
			</div>
		</div>
		<div class="clear"></div>
	</form>
</div>
</body>
</html>
<script>
	UE.getEditor('md-editor2', {
		textarea:'content',
	})
</script>
</html>